// default package
// Generated 28 Jul, 2014 8:04:07 PM by Hibernate Tools 3.4.0.CR1
package com.galaxy.bean;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * RatingOptionVoteAggregated generated by hbm2java
 */
@Entity
@Table(name = "rating_option_vote_aggregated", catalog = "magento")
public class RatingOptionVoteAggregated implements java.io.Serializable {
	private static final long serialVersionUID = 121323L;

	private Integer primaryId;
	private Rating rating;
	private CoreStore coreStore;
	private long entityPkValue;
	private int voteCount;
	private int voteValueSum;
	private short percent;
	private Short percentApproved;

	public RatingOptionVoteAggregated() {
	}

	public RatingOptionVoteAggregated(Rating rating, CoreStore coreStore,
			long entityPkValue, int voteCount, int voteValueSum, short percent) {
		this.rating = rating;
		this.coreStore = coreStore;
		this.entityPkValue = entityPkValue;
		this.voteCount = voteCount;
		this.voteValueSum = voteValueSum;
		this.percent = percent;
	}

	public RatingOptionVoteAggregated(Rating rating, CoreStore coreStore,
			long entityPkValue, int voteCount, int voteValueSum, short percent,
			Short percentApproved) {
		this.rating = rating;
		this.coreStore = coreStore;
		this.entityPkValue = entityPkValue;
		this.voteCount = voteCount;
		this.voteValueSum = voteValueSum;
		this.percent = percent;
		this.percentApproved = percentApproved;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "primary_id", unique = true, nullable = false)
	public Integer getPrimaryId() {
		return this.primaryId;
	}

	public void setPrimaryId(Integer primaryId) {
		this.primaryId = primaryId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "rating_id", nullable = false)
	public Rating getRating() {
		return this.rating;
	}

	public void setRating(Rating rating) {
		this.rating = rating;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "store_id", nullable = false)
	public CoreStore getCoreStore() {
		return this.coreStore;
	}

	public void setCoreStore(CoreStore coreStore) {
		this.coreStore = coreStore;
	}

	@Column(name = "entity_pk_value", nullable = false)
	public long getEntityPkValue() {
		return this.entityPkValue;
	}

	public void setEntityPkValue(long entityPkValue) {
		this.entityPkValue = entityPkValue;
	}

	@Column(name = "vote_count", nullable = false)
	public int getVoteCount() {
		return this.voteCount;
	}

	public void setVoteCount(int voteCount) {
		this.voteCount = voteCount;
	}

	@Column(name = "vote_value_sum", nullable = false)
	public int getVoteValueSum() {
		return this.voteValueSum;
	}

	public void setVoteValueSum(int voteValueSum) {
		this.voteValueSum = voteValueSum;
	}

	@Column(name = "percent", nullable = false)
	public short getPercent() {
		return this.percent;
	}

	public void setPercent(short percent) {
		this.percent = percent;
	}

	@Column(name = "percent_approved")
	public Short getPercentApproved() {
		return this.percentApproved;
	}

	public void setPercentApproved(Short percentApproved) {
		this.percentApproved = percentApproved;
	}

}
